<!DOCTYPE html>
<html class="pixel-ratio-2 retina android android-6 android-6-0">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no, minimal-ui" />
    <meta content="yes" name="apple-mobile-web-app-capable" />
    <meta content="black" name="apple-mobile-web-app-status-bar-style" />
    <meta name="format-detection" content="telephone=no" />
    <title>首页</title>
    <link rel="stylesheet" href="sx_assets/css/style.css">
	<link rel="stylesheet" href="sx_assets/css/mui.min.css">
	<link rel="stylesheet" href="sx_assets/font/iconfont.css">
</head>
	<body>
		<div id="vue_det">
			<!-- 标题栏 -->
			<div class="navigation-bar">
				<div class="navigation-bar-title">电表管理</div>
				<div class="navigation-left">
					<div class="navigation-left-title" v-on:click="goBack()"><li class="iconfont fs16">&#xe644;</li></div>
				</div>
				<div class="navigation-right">
					<div class="navigation-right-title">
						<i class="iconfont fs16">&#xe784;</i>
					</div>
				</div>
			</div>
			<!--  -->
			<div class="search-input-view" >
				<div class="search-input-icon">
					<i class="iconfont">&#xe608;</i>
				</div>
				<div class="search-input-input">
					<input type="input" class="input-clear" style="width: 100%;height: 38px;line-height: 38px;font-size: 14px;color: #333333;" placeholder="搜索">
				</div>
			<!-- 	<div class="search-input-btn"  >搜索</div> -->
			</div>
			<!-- 内容 -->
			<div class="content">
				
				<div class="table-view" v-on:click="window.location.href = 'meterEdit.html'">
					<div class="table-view-cell-left w12 table-view-lin">
						<div><i class="iconfont icon colorA fs16">&#xe6da;</i></div>
					</div>
					<div class="table-view-cell-left w70">
						<h4 class="ellipsis">表名</h4>
						<p class="min-ellipsis">通讯地址</p>
					</div>
					<div  class="table-view-cell-left w12 table-view-lin tr"><i class="iconfont color9">&#xe6a4;</i></div>
				</div>
				<div class="table-view" v-on:click="window.location.href = 'meterEdit.html'">
					<div class="table-view-cell-left w12 table-view-lin">
						<div><i class="iconfont icon colorA fs16">&#xe6da;</i></div>
					</div>
					<div class="table-view-cell-left w70">
						<h4 class="ellipsis">表名</h4>
						<p class="min-ellipsis">通讯地址</p>
					</div>
					<div  class="table-view-cell-left w12 table-view-lin tr"><i class="iconfont color9">&#xe6a4;</i></div>
				</div>
				<div class="table-view" v-on:click="window.location.href = 'meterEdit.html'">
					<div class="table-view-cell-left w12 table-view-lin">
						<div><i class="iconfont icon colorA fs16">&#xe6da;</i></div>
					</div>
					<div class="table-view-cell-left w70">
						<h4 class="ellipsis">表名</h4>
						<p class="min-ellipsis">通讯地址</p>
					</div>
					<div  class="table-view-cell-left w12 table-view-lin tr"><i class="iconfont color9">&#xe6a4;</i></div>
				</div>
				<div class="table-view" v-on:click="window.location.href = 'meterEdit.html'">
					<div class="table-view-cell-left w12 table-view-lin">
						<div><i class="iconfont icon colorA fs16">&#xe6da;</i></div>
					</div>
					<div class="table-view-cell-left w70">
						<h4 class="ellipsis">表名</h4>
						<p class="min-ellipsis">通讯地址</p>
					</div>
					<div  class="table-view-cell-left w12 table-view-lin tr"><i class="iconfont color9">&#xe6a4;</i></div>
				</div>
			</div>
		</div>
	</body>
</html>
<script src="sx_assets/js/vue.min.js"></script>
<script src="sx_assets/js/vconsole.min.js"></script>
<script>
	// 初始化
	var vConsole = new VConsole();
	console.log('test');
	var dbName = 'xiansun';
	var vm = new Vue({
		el: '#vue_det',
		data: {
			selCollect:'000000000000',
		},
		created: function () {
			this.docReady();
			this.createDatabase(dbName);
		},
		methods: {
			docReady:function(){
				document.addEventListener('PHJSReady', function() {
				    
				});
			},
			goBack:function(){
				window.location.href = 'index.html';
			},
			createDatabase:function(dbName){
				var result = PHDatabase.createDatabase({"dbName":dbName}, function(res) {
					console.log("成功创建数据库::" + JSON.stringify(res));
				}, function(res) {
				    console.log("创建数据库失败::" + JSON.stringify(res));
				});
				console.log("创建数据库后返回结果::" + JSON.stringify(result));
			},
		}
	})
</script>
